﻿#ifndef FORMULA_H
#define FORMULA_H

#include <QObject>
#include "product.h"
#include "formulabase.h"
#include "dbhelper.h"

class Formula : public QObject
{
    Q_OBJECT
public:
    explicit Formula(QObject *parent = nullptr);

    Formula(FormulaBase *formulaBase);

    FormulaBase *formulaBase;

    void setCombineProduct(Product *product);

    Product* getCombineProduct();

    void setSplitProducts(QList<Product*> products);

    QList<Product*> getSplitProducts();

signals:

public slots:

private:
    DbHelper helper;

    Product *combineProduct;
    QList<Product*> splitProducts;
};

#endif // FORMULA_H
